Linear Block Code is a fixed-length code block, which may be expressed as (n, k), and generally be used for forward error correction. During encoding, k information bits may be encoded into an n-bit code block length. Because 2k code words of the block code [n, k, d] form a k-dimension subspace, wherein d is the minimal code distance, then the 2k code words can definitely be generated by k linearly independent bases; if the k bases are written in the form of a matrix, then
  G  =      [                                        g                          1              ,                              n                -                1                                                                          g                          1              ,                              n                -                2                                                              …                                      g                          1              ,              0                                                                        g                          2              ,                              n                -                1                                                                          g                          2              ,                              n                -                2                                                              …                                      g                          2              ,              0                                                            ⋮                          ⋮                                                                          ⋮                                                  g                          k              ,                              n                -                1                                                                          g                          k              ,                              n                -                2                                                              …                                      g                          k              ,              0                                            ]  
wherein any code word in the block code [n, k, d] can be generated based on a linear combination of this group of bases, i.e.,
  C  =            m      ·              G        ⁡                  [                                    m              1                        ⁢                                                  ⁢                          m                              2                ⁢                                                                                        ⁢            ⋯            ⁢                                                  ⁢                          m                              n                -                k                                              ]                      ⁢          •      ⁡              [                                                            g                                  1                  ,                                      n                    -                    1                                                                                                      g                                  1                  ,                                      n                    -                    2                                                                                      …                                                      g                                  1                  ,                  0                                                                                                        g                                  2                  ,                                      n                    -                    1                                                                                                      g                                  2                  ,                                      n                    -                    2                                                                                      …                                                      g                                  2                  ,                  0                                                                                        ⋮                                      ⋮                                                                                                          ⋮                                                                          g                                  k                  ,                                      n                    -                    1                                                                                                      g                                  k                  ,                                      n                    -                    2                                                                                      …                                                      g                                  k                  ,                  0                                                                    ]            
G is called a generated matrix of codes. Obviously, for individual rows in the generated matrix, it would suffice as long as the rows satisfy linear independence (without considering the minimum distance), while a k-dimension basis can arbitrarily choose k linearly independent vectors, therefore the generated matrix G of codes is also not unique; however, no matter which form is adopted, the same subspace, i.e., the same block code [n, k, d] can always be generated.
As a linear block cyclic code, an RS code (Reed-Solomon Code) takes a group of symbols with a length of n (generally n=8 bit, called an coded word) as a processing unit, wherein the n symbols in the group are generated by k information symbols that are to be transmitted according to a certain correlation relation. Since these n symbols should also contain error code protection information, it is required to use (n, k) to express the encoding form while k<n, therefore, when n=8, there are a total of 28=256 symbols, and the range of the symbols expressed in decimal form is 0-255. These 256 symbols constitute a finite field (called the Galois Field) GF (28). In general, the finite field is expressed by GF (2m) when it is an extension field of a binary field GF (2). In the GF (2m) field, for an RS code (n, k) that can correct t errors, the number of check symbols is 2×t, and the minimum code distance is dmin=2×t+1=n−k+1 (the check matrix is a non-singular matrix). An error of 1 symbol may mean an error that occurs in 1 bit in the symbol, or an error that occurs in several bits or even all m bits in the symbol. It therefore can be seen that the RS code offers an extremely powerful ability to correct random errors and burst errors, and thus is very broadly applied in the field of digital error control.
A link layer is required to provide a network layer with data transfer service, which is carried out depending on functions equipped with the link layer. The functions equipped with the link layer include: establishment and removal of a data link, frame transmission and frame synchronization, error and flow control, and data link management. As an addition to a forward error correction technology of a physical link layer, Forward Error Correction (FEC) of the link layer is used to implement the function of error control of the link layer and to ensure that the next higher layer protocol can receive an error-free datagram. Given the superior performance, the RS code is very suitable as a Link Layer Forward Error Correction code.
Interleavers commonly used in digital communications may be classified as byte interleavers and bit interleavers according to interleaving objects. The byte interleaver is mainly used to disorganize the original byte sequence to make wrong positions to look like random, and to weaken the correlation of the byte sequence before and after interleaving and to make it distributed among many code words rather than among several code words only. An outstanding advantage of doing so is that the impact of data burst errors is greatly reduced.
In order to further improve the performance of the link layer FEC, an RS encoder is often used together with the byte interleaver, which acts as an RS code interleaving encoding method (Reed-Solomon Code with Byte Interleaver). In general, a row-column interleaver may be used as the byte interleaver, wherein the number of columns equals the code length of the RS code and the number of rows varies with the number of code blocks. For example, the byte interleaver for the RS (255, 207) code is fixed to have 255 columns, wherein the 207 columns on the left side are an information region and the 48 columns on the right side are a check region. In an existing RS code interleaving encoding method, when a traffic data packet is inputted into the byte interleaver, firstly, the 0th column may be filled in an order from the top down, once the 0th column is filled up, the 1st column may then be filled in an order from the top down, and so on, until all data in the traffic data packet are completely filled into the interleaver, and as to the unfilled portions in the first 207 column, 0 may be filled in. A check value of each row contains 48 bits, and such a check value is generated based on data information of the first 207 bits. The form after interleaved encoding is shown in FIG. 1. When data in the interleaver is outputted, it begins from the 0th column to output data in an order from the top down, upon completion of output of the 0th column, data in the 1st column may then be outputted in an order from the top down, until all data in the 255 columns are completely outputted. Rows or columns of the interleaver may, but are not limited to be numbered from 0, however, in order to maintain consistency of descriptions, the numbering all starts from 0 in the present invention.
The existing RS code interleaving encoding method has the following defects: those portions with the filled value of 0 in the information region are congregated together, this would result in that the continuous time regions corresponding to the latter rows with the filled value of 0 relatively obtain overprotection, while the continuous time regions corresponding to the previous rows get relatively less protection. Even though the data of the check region are generated in a row manner and are read out in a column manner, the interleaving among data during output is too regular to offer the best interleaving effect, therefore the performance of the entire outputted data packet can not be optimal.